package com.example.demo.util;

import cn.hutool.db.Db;
import cn.hutool.db.Entity;
import cn.hutool.db.ds.DSFactory;

import javax.sql.DataSource;
import java.sql.SQLException;
import java.util.List;

/**
 * @author BleethNie
 * @version 1.0
 * @date 2020/10/26 14:35
 **/
public class DataBaseTest {
    public static void main(String[] args) throws SQLException {
        DataSource ds1 = DSFactory.get("group_db1");
        List<Entity> student = Db.use(ds1).findAll("student");
        System.err.println(student);
    }
}
